<?php
class Tourism_goods_category_spec_model extends CI_Model
{
    private $table   = 'tourism_goods_category_spec';
    private $table_1 = 'tourism_goods_category_attribute';

    public function findBySpec($specId)
    {
        $this->db->select('attribute.attr_name,spec.*');
        $this->db->from($this->table . ' AS spec ');
        $this->db->join($this->table_1.' AS attribute','spec.attr_id = attribute.attr_id');
        $this->db->where_in('spec.spec_id', $specId);
        return $this->db->get();
    }
    
}